package ControlLayer;



import static org.junit.Assert.*;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;

/**
 * The test class TestSupplier.
 *
 * @author  (your name)
 * @version (a version number or a date)
 */
public class TestSupplier
{
    /**
     * Default constructor for test class TestSupplier
     */
    public TestSupplier()
    {
    }

    /**
     * Sets up the test fixture.
     *
     * Called before every test case method.
     */
    @Before
    public void setUp()
    {
    }

    /**
     * Tears down the test fixture.
     *
     * Called after every test case method.
     */
    @After
    public void tearDown()
    {
    }

    @Test
    public void createSupplier()
    {
        ControlLayer.SupplierCtr supplier1 = new ControlLayer.SupplierCtr();
        supplier1.createSupplier("google", "aalborg", "vesterbro", 9700, 123456);
    }

    @Test
    public void findSupplier()
    {
        ControlLayer.SupplierCtr supplier1 = new ControlLayer.SupplierCtr();
        supplier1.createSupplier("google", "aalborg", "vesterbro", 9700, 123456);
        supplier1.findSupplier(123456);
    }

    @Test
    public void updateSupplier()
    {
        ControlLayer.SupplierCtr supplier1 = new ControlLayer.SupplierCtr();
        supplier1.createSupplier("google", "aalborg", "vesterbro", 9700, 123456);
        supplier1.updateSupplier("apple", "KBH", "vesterbro", 9000, 123456);
    }

    @Test
    public void deleteSupplier()
    {
        ControlLayer.SupplierCtr supplier1 = new ControlLayer.SupplierCtr();
        supplier1.createSupplier("google", "aalborg", "vesterbro", 9700, 123456);
        supplier1.deleteSupplier(123456);
    }
}




